//
// Created by Administrator on 2025/4/21/周一.
//
#include "iostream"

using namespace std;

class Building {
    //这一行代码的意义在于让这个函数可以访问building对象中的私有属性
    friend void goodGay(Building *building);

public:
    string m_SettingRoom;//客厅
private:
    string m_BedRoom;//卧室
public:
    Building() {
        m_SettingRoom = "客厅";
        m_BedRoom = "卧室";
    }

};

void goodGay(Building *building) {
    cout << "好朋友正在访问" << building->m_SettingRoom << endl;
    cout << "好朋友正在访问" << building->m_BedRoom << endl;
}

void test01() {
    Building b;
    goodGay(&b);
}

int main() {
    test01();
}